package com.dream.model;

import java.io.Serializable;
import java.util.List;

import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.OneToMany;
import javax.persistence.Table;

import org.hibernate.annotations.BatchSize;
import org.hibernate.annotations.Cascade;
import org.hibernate.annotations.CascadeType;

@Entity
@Table(name = "sys_honor")
public class Sys_honor extends AllId implements Serializable
{

	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;

	private String honorName;//荣誉名称

	private Integer honorValue;//荣誉值 

	private String honorNote;//荣誉刘明

	private String type;//类型

	private List<Sys_User_Honor> listsuh = null;//一个荣誉，可以有多个学生
	
	@OneToMany(fetch = FetchType.LAZY, mappedBy = "sys_honor", orphanRemoval = true)
	@Cascade(value = { CascadeType.SAVE_UPDATE })
	@BatchSize(size = 20)
	public List<Sys_User_Honor> getListsuh()
	{
		return listsuh;
	}

	public void setListsuh(List<Sys_User_Honor> listsuh)
	{
		this.listsuh = listsuh;
	}
	public String getHonorName()
	{
		return honorName;
	}

	public void setHonorName(String honorName)
	{
		this.honorName = honorName;
	}

	public Integer getHonorValue()
	{
		return honorValue;
	}

	public void setHonorValue(Integer honorValue)
	{
		this.honorValue = honorValue;
	}

	public String getHonorNote()
	{
		return honorNote;
	}

	public void setHonorNote(String honorNote)
	{
		this.honorNote = honorNote;
	}

	public String getType()
	{
		return type;
	}

	public void setType(String type)
	{
		this.type = type;
	}

	public static long getSerialversionuid()
	{
		return serialVersionUID;
	}
	
	
	

}
